package renguanyu.app.tools.util;

import java.awt.Toolkit;
import java.awt.datatransfer.Clipboard;
import java.awt.datatransfer.StringSelection;
import java.awt.datatransfer.Transferable;

public class SystemUtil {

	public static String getCurrentPath() {
		String cwd = System.getProperty("user.dir");
		return cwd;
	}

	public static boolean isDevEnv() {
		String env = System.getenv("Env");
		if ("Dev".equals(env)) {
			return true;
		}
		return false;
	}

	public static void copyString(String content) {
		Toolkit defaultToolkit = Toolkit.getDefaultToolkit();
		Clipboard clipboard = defaultToolkit.getSystemClipboard();
		Transferable transferable = new StringSelection(content);
		clipboard.setContents(transferable, null);
	}

}
